<?php defined('KX_ROOT') || exit('Permission denied');?><!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8" name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no">
    <meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">
    <title><?php include \Kuxin\View::parseTpl($tkd['title']);?></title>
    <meta name="keywords" content="<?php include \Kuxin\View::parseTpl($tkd['keywords']);?>">
    <meta name="description" content="<?php include \Kuxin\View::parseTpl($tkd['description']);?>">
	<link rel="stylesheet" href="<?php echo \Kuxin\Helper\Arr::getValue($_kxcms_config, "resurl");?>/template/kxmobileno1/css/global.css"/>
	<script src="<?php echo \Kuxin\Helper\Arr::getValue($_kxcms_config, "resurl");?>/template/kxmobileno1/js/flexible.min.js"></script>
    <link rel="shortcut icon" type="image/ico" href="/favicon.ico" />
    <meta name="author" content="www.ptcms.com">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    <meta name="renderer" content="webkit">
    <meta name="viewport" content="width=device-width" />
    <meta name="applicable-device" content="pc">
    <meta http-equiv="mobile-agent" content="format=html5; url=<?php echo \Kuxin\Helper\Arr::getValue($_kxcms_config, "mobileurl");?><?php echo $_SERVER['REQUEST_URI'];?>">
    <meta http-equiv="Cache-Control" content="no-siteapp" />
    <meta http-equiv="Cache-Control" content="no-transform" />
    <link rel="canonical" href="<?php echo \Kuxin\Helper\Arr::getValue($_kxcms_config, "pcurl");?><?php echo $_SERVER['REQUEST_URI'];?>" />
	<style>
        .pt-search {
            width: 100%;
            padding: 0.20rem;
            border-radius: 0.02rem;
        }

        .pt-search-box {
            width: 80vw;
            height: 0.30rem;
            background-color: #f2f2f7;
            padding-left: 0.13rem;
        }

        .pt-recall {
            font-size: 0.1rem;
        }

        .history {
            background-color: #fff;
            margin: 10px;
            padding: 10px;
        }
        .history h1{
            font-size: 16px;
            color: #666;
            margin-bottom: 10px;
        }
        .history h1 span{
            font-size: 12px;
            float: right;
        }
        .history ul li{
            display: inline-block;
            background-color: #f0f0f0;
            padding: 3px 10px;
            border-radius: 4px;
            margin: 5px;
        }
	</style>
</head>
<body>
    <form action="<?php echo \Kuxin\Helper\Url::build("novel.search.result",[],"");?>" class="searchForm">
        <div class="w100 bg-white flex-wrp flex-between flex-align-center pt-search">
            <div class="flex-wrp flex-align-center pt-search-box" style="width: 80vw;">
                <img src="<?php echo \Kuxin\Helper\Arr::getValue($_kxcms_config, "resurl");?>/template/kxmobileno1/images/search.png" class="mr10 pt-search-icon" >
                <input type="text" name="searchkey" class="size12 color4" style="width: 100%" placeholder="请输入您要搜索的关键书名">
            </div>
            <div class="pt-recall">取消</div>
        </div>
    </form>
    <div class="history">
        <h1>历史搜索 <span>清空</span></h1>
        <ul></ul>
    </div>

    <!-- 底部版权 -->
    <div class="pt-copyright">
    <div class="size12  w100 text-center mt15 mb10"><a title="隐私声明" href="<?php echo \Kuxin\Helper\Url::build("page.detail",['key'=>'privacy'],"");?>" class="color4">隐私声明</a> | <a title="免责声明" href="<?php echo \Kuxin\Helper\Url::build("page.detail",['key'=>'disdaimer'],"");?>" class="color4">免责声明</a> | <a title="关于我们" href="<?php echo \Kuxin\Helper\Url::build("page.detail",['key'=>'about'],"");?>" class="color4">关于我们</a></div>
    <div class="size12 color4 w100 text-center mb10">Copyright © 2009-<?php echo date(Y);?> <?php echo \Kuxin\Helper\Arr::getValue($_kxcms_config, "beian");?></div>
    <div class="size12  w100 text-center"><?php echo \Kuxin\Response::runinfo();?></div>
</div>
<!-- js -->
<script src="<?php echo \Kuxin\Helper\Arr::getValue($_kxcms_config, "resurl");?>/template/kxmobileno1/js/jquery-3.3.1.js"></script>
<script>
    $('.pt-return,.pt-recall').click(function(){
        window.history.back();
    });
    $('.pt-ellipsis').click(function(){
        $('.pt-tip').toggle()
    });
    $('.pt-tip .pt-tip-item').click(function(){
        $('.pt-tip').toggle()
    });
</script>
<div class="none">
    <?php echo \Kuxin\Helper\Arr::getValue($_kxcms_config, "tongji.mobile");?>
    <?php if(\Kuxin\Helper\Arr::getValue($_kxcms_config, "app.use_cdn")):?>
    <script src="/api/stat/novel/info.js"></script>
    <script src="/api/stat/novel/read.js"></script>
    <?php endif;?>
</div>
    <script>
        var historyStr = window.localStorage.getItem('search_history');
        historyList = typeof historyStr === 'string' ? historyStr.split('|||') : [];
        $.each(historyList, function (k, v) {
            if(v){
                $('.history ul').append('<li><a href="<?php echo \Kuxin\Helper\Url::build("novel.search.result",[],"");?>?searchkey=' + encodeURI(v) + '">' + v + '</a></li>');
            }
        });
        $('.searchForm img').click(function () {
            $('.searchForm').submit();
        });
        $('.searchForm').submit(function () {
            historyList.push($('.searchForm input[name=searchkey]').val());
            var uniqueArr = [];
            $.each(historyList, function(i, el){
                if($.inArray(el, uniqueArr) === -1) uniqueArr.push(el);
            });
            window.localStorage.setItem('search_history', uniqueArr.join('|||'));
        });
        $('.history h1 span').click(function () {
            $('.history ul li').remove();
            window.localStorage.removeItem('search_history');
        });
    </script>
</body>
</html>